home *** CD-ROM | disk | FTP | other *** search
/ Magnum One / Magnum One (Mid-American Digital) (Disc Manufacturing).iso / d18 / vis082s.arc / OVERRET1.PAS < prev    next >
Pascal/Delphi Source File  |  1991-04-17  |  25KB  |  786 lines

  1. {$R-,S-,I-,D-,F+,V-,B-,N-,L+,O+ }
  2.  
  3. unit overret1;
  4.  
  5. interface
  6.  
  7. uses crt,dos, windows,
  8. gentypes,modem,configrt,gensubs,subs1,subs2,userret,textret,flags,mainr1;
  9.  
  10. (*procedure smartnews;*)
  11. procedure help (fn:mstr);
  12. procedure sendmodemstr (ss:anystr; endifcarrier:boolean);
  13. function getlastcaller:mstr;
  14. procedure infoform(num:integer);
  15. Procedure UserFileListing;
  16. Procedure NewVoteX;
  17. Procedure CheckVot;
  18. Procedure BoXFile;
  19. Procedure ListingHelp;
  20. Procedure newscanhelp;
  21. function searchforfile (f:sstr):integer;
  22. function allowbaud:boolean;
  23. function allowxfer:boolean;
  24. Procedure getstring(t:lstr;Var m);
  25. Procedure getint(t:lstr;Var i:Integer);
  26. Procedure getboo(t:lstr;Var b:Boolean);
  27.  
  28. implementation
  29.  
  30.   Function searchforfile(f:sstr):Integer;
  31.     Var ud:udrec;
  32.       cnt:Integer;
  33.     Begin
  34.       For cnt:=1 To filesize(udfile) Do Begin
  35.         seek (udfile,cnt - 1);
  36.         Read(udfile,ud);
  37.         If match(ud.filename,f) Then Begin
  38.           searchforfile:=cnt;
  39.           exit
  40.         End
  41.       End;
  42.       searchforfile:=0
  43.     End;
  44.  
  45.    function allowbaud:boolean;
  46.    var k:integer;
  47.        cnt:baudratetype;
  48.    begin
  49.      for cnt:=firstbaud to lastbaud do if connectbaud=baudarray[cnt] then
  50.        if not (cnt in configset.downloadrate) then begin
  51.        writeln(^M^G'You may not download at ',connectbaud,' baud rate!');
  52.        allowbaud:=false;
  53.        exit;
  54.      end;
  55.    allowbaud:=true;
  56.    end;
  57.  
  58.    Function allowxfer:Boolean;
  59.     Begin
  60.       allowxfer:=False;
  61.       If Not carrier Then Begin
  62.         WriteLn(^S'You may only transfer from remote!');
  63.         exit
  64.       End;
  65.    {  if filesinbatch > 0 then begin
  66.          writeln(^S'You must first either clear or download your BATCH que!');
  67.          exit;
  68.       end; }
  69.       if not allowbaud then exit;
  70.       allowxfer:=True
  71.     End;
  72.  
  73.   Procedure getstring(t:lstr;Var m);
  74.     Var q:lstr Absolute m;
  75.       mm:lstr;
  76.     Begin
  77.       WriteLn('Old '^S,t,^R': ',q);
  78.       writestr('Enter new '+^S+t+^P+' [CR for no change]:');
  79.       mm:=Input;
  80.       If Length(mm)<>0 Then q:=mm;
  81.       WriteLn
  82.     End;
  83.  
  84.   Procedure getint(t:lstr;Var i:Integer);
  85.     Var s:sstr;
  86.     Begin
  87.       s:=strr(i);
  88.       getstring(t,s);
  89.       i:=valu(s)
  90.     End;
  91.  
  92.   Procedure getboo(t:lstr;Var b:Boolean);
  93.     Var s:sstr;
  94.     Begin
  95.       s:=yesno(b);
  96.       getstring(t,s);
  97.       b:=UpCase(s[1])='Y'
  98.     End;
  99.  
  100.  
  101. (*
  102. procedure smartnews;
  103. var nfile:file of newsrec;
  104.     line:integer;
  105.     ntemp:newsrec;
  106.     cnt:integer;
  107.     dt1,dt2:datetime;
  108.     show:boolean;
  109. begin
  110.   assign(nfile,'News');
  111.   reset(nfile);
  112.   if ioresult<>0 then exit;
  113.   if filesize(nfile)=0 then begin
  114.     close(nfile);
  115.     exit;
  116.   end;
  117.   cnt:=0;
  118.   while not(eof(nfile) or break or hungupon) do begin
  119.     read(nfile,ntemp);
  120.     inc(cnt);
  121.     if issysop or (ntemp.location>=0) and (ntemp.maxlevel>=urec.level) and (urec.level>=ntemp.level) then
  122.  
  123.      begin
  124.      unpacktime(ntemp.when,dt1);
  125.      unpacktime(laston,dt2);
  126.      show:=false;
  127.        if (ntemp.when>=laston) then show:=true;
  128.        if show then
  129.        begin
  130.        if ansigraphics in urec.config then begin
  131.        clearscr;
  132.        blowup(1,1,80,4);
  133.        printxy(2,2,' ViSiON Smart News Item #');
  134.        printzy(2,28,strr(cnt)+' - '+ntemp.title+' from '+ntemp.from);
  135.        writeln;
  136.        printxy(3,2,' Date:           Time:           Level:');
  137.        printzy(3,8,datestr(ntemp.when));
  138.        printzy(3,24,timestr(ntemp.when));
  139.        printzy(3,41,strr(ntemp.level)+' - '+strr(ntemp.maxlevel));
  140.        end else begin
  141.          writeln(^M'ViSiON Smart News Item #',cnt,' - ',ntemp.title,' From ',ntemp.from);
  142.          writeln('Date: ',datestr(ntemp.when),' Time: ',timestr(ntemp.when),' Levels: ',ntemp.level,' - ',ntemp.maxlevel);
  143.          end;
  144.        writeln(^M);
  145.        printtext(ntemp.location);
  146.        buflen:=0;
  147.        writestr(^P'Press '^S'[Return]'^P' to continue.&');
  148.        end;
  149.     end;
  150.   end;
  151.   close(nfile);
  152. end;  *)
  153.  
  154. procedure help (fn:mstr);
  155. var tf:text;
  156.     htopic,cnt:integer;
  157. begin
  158.   fn:=configset.textfiledi+fn;
  159.   assign (tf,fn);
  160.   reset (tf);
  161.   if ioresult<>0 then begin
  162.     writestr ('Sorry, no help is availiable!');
  163.     if issysop then begin
  164.       writeln ('Sysop: To make help, create a file called ',fn);
  165.       writeln ('Group the lines into blocks separated by periods.');
  166.       writeln ('The first group is the topic menu; the second is the');
  167.       writeln ('help for topic 1; the third for topic 2; etc.')
  168.     end;
  169.     exit
  170.   end;
  171.   repeat
  172.     textclose (tf);
  173.     assign (tf,fn);
  174.     reset (tf);
  175.     writeln (^M);
  176.     printtexttopoint (tf);
  177.     repeat
  178.       writestr (^M'Topic number [CR quits]:');
  179.       if hungupon or (length(input)=0) then
  180.         begin
  181.           textclose (tf);
  182.           exit
  183.         end;
  184.       htopic:=valu (input)
  185.     until (htopic>0);
  186.     for cnt:=2 to htopic do
  187.       if not eof(tf)
  188.         then skiptopoint (tf);
  189.     if eof(tf)
  190.       then writestr ('Sorry, no help on that topic!')
  191.       else printtexttopoint (tf)
  192.   until 0=1
  193. end;
  194.  
  195. procedure sendmodemstr (ss:anystr; endifcarrier:boolean);
  196. var cnt,ptr:integer;
  197.     k:char;
  198. label exit;
  199. begin
  200.   ptr:=0;
  201.   while ptr<length(ss) do
  202.     begin
  203.             if keyhit or (carrier=endifcarrier) then goto exit;
  204.       ptr:=ptr+1;
  205.       k:=ss[ptr];
  206.       case k of
  207.                 '|':sendchar (^M);
  208.         '~':delay (500);
  209.         '^':begin
  210.               ptr:=ptr+1;
  211.               if ptr>length(ss)
  212.                 then k:='^'
  213.                 else k:=upcase(ss[ptr]);
  214.               if k in ['A'..'Z']
  215.                                 then sendchar (chr(ord(k)-64))
  216.                                 else sendchar(k)
  217.             end;
  218.                 else sendchar (k)
  219.       end;
  220.       delay (50);
  221.             while numchars > 0 do writecon (getchar)
  222.     end;
  223.   cnt:=0;
  224.   repeat
  225.         while numchars > 0 do begin
  226.       cnt:=0;
  227.       writecon (getchar)
  228.     end;
  229.     cnt:=cnt+1
  230.     until (cnt=1000) or keyhit or (carrier=endifcarrier);
  231.   exit:
  232.   break:=keyhit
  233. end;
  234.  
  235. function getlastcaller:mstr;
  236. var qf:file of lastrec;
  237.     l:lastrec;
  238. begin
  239.   getlastcaller:='';
  240.   assign (qf,'Callers');
  241.   reset (qf);
  242.   if ioresult=0 then
  243.     if filesize(qf)>0
  244.       then
  245.         begin
  246.           seek (qf,0);
  247.           read (qf,l);
  248.           getlastcaller:=l.name
  249.         end;
  250.   close (qf)
  251. end;
  252.  
  253. procedure infoform(num:integer);
  254. var ff:text;
  255.     fn:lstr;
  256.     k:char;
  257.     me:message;
  258.     i:integer;
  259.     teleg:integer;
  260. begin
  261.   writeln;
  262.   fn:=configset.textfiledi+'InfoForm.'+strr(num);
  263. (*  if num>1 then fn:=fn+'.'+strr(num); *)
  264.   if not exist (fn) then begin
  265.     writestr ('There isn''t an information form right now.');
  266.     if issysop then
  267.       writeln ('Sysop: To make an information form, create a text file',
  268.              ^M'called ',fn,'.  Use * to indicate a pause for user input.');
  269.     exit
  270.   end;
  271.   if ((urec.infoform<>-1) and (num=1)) or ((urec.infoform2<>-1) and (num=2)) or
  272.      ((urec.infoform3<>-1) and (num=3)) or ((urec.infoform4<>-1) and (num=4)) or
  273.      ((urec.infoform5<>-1) and (num=5)) then begin
  274.     writestr ('You have an existing information form!  Replace it? *');
  275.     if not yes then exit;
  276.     if num=1 then teleg:=urec.infoform else if num=2 then teleg:=urec.infoform2 else
  277.     if num=3 then teleg:=urec.infoform3 else if num=4 then teleg:=urec.infoform4 else
  278.     if num=5 then teleg:=urec.infoform5;
  279.     deletetext (teleg);
  280.     if num=1 then urec.infoform:=-1 else if num=2 then urec.infoform2:=-1 else
  281.     if num=3 then urec.infoform3:=-1 else if num=4 then urec.infoform4:=-1 else
  282.     if num=5 then urec.infoform5:=-1;
  283.     writeurec
  284.   end;
  285.   assign (ff,fn);
  286.   reset (ff);
  287.   me.numlines:=1;
  288.   me.title:='';
  289.   me.anon:=false;
  290.   me.text[1]:='Filled out on: '+datestr(now)+' at '+timestr(now);
  291.   while not eof(ff) do begin
  292.     if hungupon then begin
  293.       textclose (ff);
  294.       exit
  295.     end;
  296.     read (ff,k);
  297.     if k='|' then begin
  298.       i:=0;
  299.       read(ff,k);
  300.       i:=valu(k)*10;
  301.       read(ff,k);
  302.       i:=i+valu(k);
  303.       ansicolor(i);
  304.       read(ff,k)
  305.     end;
  306.     if k='*' then begin
  307.        nochain:=true;
  308.        getstr;
  309.        me.numlines:=me.numlines+1;
  310.        me.text[me.numlines]:=input;
  311.        read(ff,k)
  312.     end;
  313.     if k='@' then begin
  314.       repeat
  315.       NoChain:=True;
  316.       getstr;
  317.        if (length(input)=0) and not hungupon then write(^M^G^P'Please Respond!'^G^R':');
  318.       until length(input)<>0;
  319.       me.numlines:=me.numlines+1;
  320.       me.text[me.numlines]:=input
  321.     end else writechar (k)
  322.   end;
  323.   textclose (ff);
  324.   if num=1 then urec.infoform:=maketext (me) else if num=2 then urec.infoform2:=maketext(me) else
  325.   if num=3 then urec.infoform3:=maketext(me) else if num=4 then urec.infoform4:=maketext(me) else
  326.   if num=5 then urec.infoform5:=maketext(me);
  327.   writeurec
  328. end;
  329.  
  330. Procedure UserFileListing;
  331. Var IT:Char;
  332.     tot,Total,frees:Integer;
  333.     Leave:Boolean;
  334.  
  335.     Procedure c9;
  336.     Begin
  337.       ColorFB(9,1);
  338.     End;
  339.  
  340.     Procedure c8;
  341.     Begin
  342.       ColorFB(0,1);
  343.     End;
  344.  
  345.     Procedure c1;
  346.     Begin
  347.       ColorFb(11,1);
  348.     End;
  349.  
  350.     Procedure c4;
  351.     Begin
  352.       ColorFb(4,1);
  353.     End;
  354.  
  355.     Procedure BG;
  356.     Begin
  357.     Ansicolor(9);
  358.     WriteLn('█');
  359.     c1;
  360.     End;
  361.  
  362.     Procedure BC;
  363.     Begin
  364.     Ansicolor(9);
  365.     write('█');
  366.     c1;
  367.     end;
  368.  
  369.     Procedure TooBad;
  370.     Begin
  371.     goxy(17,2);
  372.     WriteLn(^R'You do not have enough '^S'Free Space'^R' for that option!');
  373.     end;
  374.  
  375.     Procedure fspace;
  376.     begin
  377.     Goxy(52,16);
  378.     c8;
  379.     Write(strr(frees)+'  ');
  380.     end;
  381.  
  382. Procedure ShowIt;
  383. Begin
  384.   ClearScr;
  385.   goxy(20,4);
  386.   bc;ColorFb(9,1);Write('▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀');bg;goxy(20,5);
  387.   bc;c9;Write('   ViSiON Configurable File Listings   ');bg;goxy(20,6);c1;
  388.   bc;Write('                                       ');bg;goxy(20,7);c1;
  389.   bc;Write('    1) File Name............           ');bg;goxy(20,8);
  390.   bc;Write('    2) File Extension.......           ');bg;goxy(20,9);
  391.   bc;Write('    3) File Cost............           ');bg;goxy(20,10);
  392.   bc;Write('    4) Size Of File.........           ');bg;goxy(20,11);
  393.   bc;Write('    5) File Description.....           ');bg;goxy(20,12);
  394.   bc;Write('    6) Date Uploaded........           ');bg;goxy(20,13);
  395.   bc;WRite('    7) Popularity...........           ');bg;goxy(20,14);
  396.   bc;Write('    8) Who Uploaded.........           ');bg;goxy(20,15);ColorFb(1,7);
  397.   bc;WRite('───────────────────────────────────────');bg;goxy(20,16);c4;
  398.   bc;c9;Write('    Total Spaces Used (77/Max)         ');bg;goxy(20,17);
  399.   bc;colorfb(9,1);Write('▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄');bg;
  400. End;
  401.  
  402. Procedure ShowCurStats;
  403. Begin
  404.   Total:=0;
  405.   tot:=93;
  406.   goxy(49,7); If urec.use1=false then Begin tot:=tot-8; c9; Write('OFF'); c8; Write(' ■');
  407.       End Else Begin Total:=total+8; c9; Write('ON!'); c4; Write(' ■'); End;
  408.   goxy(49,8); If urec.use2=false then Begin tot:=tot-4; c9; Write('OFF'); c8; Write(' ■');
  409.       End Else Begin Total:=total+4; c9; Write('ON!'); c4; Write(' ■'); End;
  410.   goxy(49,9); If urec.use3=false then Begin tot:=tot-8; c9; Write('OFF'); c8; Write(' ■');
  411.       End Else Begin Total:=total+8; c9; Write('ON!'); c4; Write(' ■'); End;
  412.   goxy(49,10); If urec.use4=false then Begin tot:=tot-10; c9; Write('OFF'); c8; Write(' ■');
  413.       End Else Begin Total:=Total+10; c9; Write('ON!'); c4; Write(' ■'); End;
  414.   goxy(49,11); If urec.use5=false then Begin tot:=tot-39; c9; Write('OFF'); c8; Write(' ■');
  415.       End Else Begin Total:=total+39; c9; Write('ON!'); c4; Write(' ■'); End;
  416.   goxy(49,12); If urec.use6=false then Begin tot:=tot-10; c9; Write('OFF'); c8; Write(' ■');
  417.       End Else Begin Total:=total+10; c9; Write('ON!'); c4; Write(' ■'); End;
  418.   goxy(49,13); If urec.use7=false then Begin tot:=tot-4; c9; Write('OFF'); c8; Write(' ■');
  419.       End Else Begin Total:=total+4; c9; Write('ON!'); c4; Write(' ■'); End;
  420.   goxy(49,14); If urec.use8=false then Begin tot:=tot-20; c9; Write('OFF'); c8; Write(' ■');
  421.       End Else Begin Total:=total+20; c9; Write('ON!'); c4; Write(' ■'); End;
  422.   goxy(52,16);
  423.   frees:=total;
  424.   Write(strr(frees)+'  ');
  425.   End;
  426.  
  427. Procedure GetuserInput;
  428. Begin
  429.   IT:=' ';
  430.   Repeat
  431.     Repeat
  432.       If hungupon then exit;
  433.       Until Charready or hungupon;
  434.     It:=ReadChar;
  435.     If Length(it)=0 then it:=' ';
  436.     It:=Upcase(It)
  437.     Until (Pos(It,'12345678Q')>0) or hungupon;
  438.     If It='1' then Begin
  439.       If urec.use1=false then urec.use1:=True Else urec.use1:=False;
  440.       goxy(49,7); If urec.use1=false then Begin frees:=frees-8; c9; Write('OFF'); c8; Write(' ■');
  441.       End Else Begin frees:=frees+8; c9; Write('ON!'); c4; Write(' ■'); End;
  442.       If frees>77 then begin urec.use1:=False; frees:=frees-8; TooBad; ShowCurstats; End;
  443.       fspace;
  444.     End;
  445.     If It='2' then Begin
  446.       If urec.use2=false then urec.use2:=True Else urec.use2:=False;
  447.       goxy(49,8); If urec.use2=false then Begin frees:=frees-4; c9; Write('OFF'); c8; Write(' ■');
  448.       End Else Begin frees:=frees+4; c9; Write('ON!'); c4; Write(' ■'); End;
  449.       If frees>77 then begin urec.use2:=False; frees:=frees-4; toobad; showcurstats;End;
  450.       fspace;
  451.     End;
  452.     If It='3' then Begin
  453.       If urec.use3=false then urec.use3:=True Else urec.use3:=False;
  454.       goxy(49,9); If urec.use3=false then Begin frees:=frees-8; c9; Write('OFF'); c8; Write(' ■');
  455.       End Else Begin frees:=frees+8; c9; Write('ON!'); c4; Write(' ■'); End;
  456.       If frees>77 then begin urec.use3:=False; frees:=frees-8; toobad; showcurstats;End;
  457.       fspace;
  458.     End;
  459.     If It='4' then Begin
  460.       If urec.use4=false then urec.use4:=True Else urec.use4:=False;
  461.       goxy(49,10); If urec.use4=false then Begin frees:=frees-10; c9; Write('OFF'); c8; Write(' ■');
  462.       End Else Begin frees:=frees+10; c9; Write('ON!'); c4; Write(' ■'); End;
  463.       If frees>77 then Begin urec.use4:=False; frees:=frees-10; toobad; showcurstats;End;
  464.       fspace;
  465.     End;
  466.     If It='5' then Begin
  467.       If urec.use5=false then urec.use5:=True Else urec.use5:=False;
  468.       goxy(49,11); If urec.use5=false then Begin frees:=frees-39; c9; Write('OFF'); c8; Write(' ■');
  469.       End Else Begin frees:=frees+39; c9; Write('ON!'); c4; Write(' ■'); End;
  470.       If frees>77 then Begin urec.use5:=False; frees:=frees-39; toobad; showcurstats;End;
  471.       fspace;
  472.     End;
  473.     If It='6' then Begin
  474.       If urec.use6=false then urec.use6:=True Else urec.use6:=False;
  475.       goxy(49,12); If urec.use6=false then Begin frees:=frees-10; c9; Write('OFF'); c8; Write(' ■');
  476.       End Else Begin frees:=frees+10; c9; Write('ON!'); c4; Write(' ■'); End;
  477.       If frees>77 then Begin urec.use6:=False; frees:=frees-10; toobad; showcurstats;End;
  478.       fspace;
  479.     End;
  480.     If It='7' then Begin
  481.       If urec.use7=false then urec.use7:=True Else urec.use7:=False;
  482.       goxy(49,13); If urec.use7=false then Begin frees:=frees-4; c9; Write('OFF'); c8; Write(' ■');
  483.       End Else Begin frees:=frees+4; c9; Write('ON!'); c4; Write(' ■'); End;
  484.       If frees>77 then Begin urec.use7:=False; frees:=frees-4; toobad; showcurstats;End;
  485.       fspace;
  486.     End;
  487.     If It='8' then Begin
  488.       If urec.use8=false then urec.use8:=True Else urec.use8:=False;
  489.       goxy(49,14); If urec.use8=false then Begin frees:=frees-20; c9; Write('OFF'); c8; Write(' ■');
  490.       End Else Begin frees:=frees+20; c9; Write('ON!'); c4; Write(' ■'); End;
  491.       if frees>77 then Begin urec.use8:=False; frees:=frees-20; toobad; showcurstats;End;
  492.       fspace;
  493.     End;
  494.     If it='Q' then Begin
  495.       Leave:=True;
  496.       WriteUrec;
  497.     End;
  498.   End;
  499.  
  500. Begin
  501.   Leave:=False;
  502.   ShowIt;
  503.   ShowCurStats;
  504.   PrintXy(19,23,^R'Please Configure '^S'Your'^R' File Listings');
  505.   Repeat
  506.     goxy(30,20);
  507.     Write(^R'Choice (Q/uit)'^P':');
  508.     GetUserInput;
  509.   Until Leave=True;
  510. End;
  511.  
  512. function checit(num:integer;name:anystr):boolean;
  513.    var
  514.      x:integer;
  515.    begin
  516.      checit:=true;
  517. (*     for x:=1 to 50 do
  518.      if urec.newvoteit[x]=num then checit:=false; *)
  519.      If urec.nuv1=name then checit:=false;
  520.      If urec.nuv2=name then checit:=false;
  521.      if urec.nuv3=name then checit:=false;
  522.      If urec.nuv4=name then checit:=false;
  523.      if urec.nuv5=name then checit:=false;
  524. (*     if urec.nuv6=name then checit:=false;
  525.      if urec.nuv7=name then checit:=false;
  526.      if urec.nuv8=name then checit:=false;
  527.      if urec.nuv9=name then checit:=false;
  528.      if urec.nuv10=name then checit:=false; *)
  529.    end;
  530.  
  531. procedure newvotex;
  532. var u:userrec;
  533.     n,cnt1,cnt:integer;
  534.     cv,alv:boolean;
  535.     info,name:Mstr;
  536.     quit:boolean;
  537.  
  538.   procedure look;
  539.   var cntz:integer;
  540.    begin
  541.    cnt1:=0;
  542.    alv:=false;
  543.    for cntz:=1 to 50 do begin
  544.     if urec.newvoteit[cntz]=n then begin
  545.      alv:=true;
  546.      cntz:=50;
  547.      end;
  548.     end;
  549.    end;
  550.  
  551.    Procedure addnuv;
  552.      Procedure throwup;
  553.      begin
  554.      urec.nuv9:=urec.nuv10;
  555.      urec.nuv8:=urec.nuv9;
  556.      urec.nuv7:=urec.nuv8;
  557.      urec.nuv6:=urec.nuv7;
  558.      urec.nuv5:=urec.nuv6;
  559.      urec.nuv4:=urec.nuv5;
  560.      urec.nuv3:=urec.nuv4;
  561.      urec.nuv2:=urec.nuv3;
  562.      urec.nuv1:=u.handle;
  563.      End;
  564.    Begin
  565.    if urec.nuv1='' then urec.nuv1:=u.handle else
  566.    if urec.nuv2='' then urec.nuv2:=u.handle else
  567.    if urec.nuv3='' then urec.nuv3:=u.handle else
  568.    if urec.nuv4='' then urec.nuv4:=u.handle else
  569.    if urec.nuv5='' then urec.nuv5:=u.handle else
  570.    if urec.nuv6='' then urec.nuv6:=u.handle else
  571.    if urec.nuv7='' then urec.nuv7:=u.handle else
  572.    if urec.nuv8='' then urec.nuv8:=u.handle else
  573.    if urec.nuv9='' then urec.nuv9:=u.handle else
  574.    if urec.nuv10='' then urec.nuv10:=u.handle else throwup;
  575.    end;
  576.  
  577. procedure showuser;
  578.   begin
  579.     writeln;
  580.     If alv then begin
  581. ClearScr;
  582. WriteLn(^U'ViSiON - New User Voting'^M);
  583. Writeln(^P'User Handle : '^R+u.handle);
  584. Writeln;
  585. Writeln(^P'Number of '^U'YES'^P' Votes Recieved'^R'.. '^S+strr(u.newvoteyes));
  586. Writeln(^P'Number of '^U'NO'^P' Votes Recieved'^R'... '^S+strr(u.newvoteno));
  587. Writeln(^P'# of Votes to be Validated'^R'.... '^S+strr(configset.vonum));
  588. WriteLn(^P'# of Votes to be Deleted'^R'...... '^S+strr(configset.vonumNo));
  589. Writeln(^P'# of Yes Votes User Needs'^R'..... '^S+strr(configset.vonum-u.newvoteyes));
  590. writeln;
  591.     cv:=False;
  592.     repeat
  593.     Input[1]:=' ';
  594.     WriteStr(^R'New User Voting '^P'- ['^S'?/Help'^P']:*');
  595.     If Upcase(Input[1])='' then Input[1]:=' ';
  596.     info:=Upcase(Input[1]);
  597.     If info='Y' then begin
  598.          cv:=false;
  599.          cnt:=0;
  600.          seek (ufile,n);
  601.          u.newvoteyes:=u.newvoteyes+1;
  602.          addnuv;
  603.          while cnt<=50 do begin
  604.          if urec.newvoteit[cnt]=0 then begin
  605.          urec.newvoteit[cnt]:=n;
  606.          cnt:=50;
  607.          if u.newvoteyes>=configset.vonum
  608.          then begin
  609.          u.level:=configset.volvl;
  610.          u.udlevel:=configset.voflvl;
  611.          u.udpoints:=configset.vofps;
  612.          Writeln('User Has Been Auto-Validated...');
  613.          end
  614.          else
  615.          Writeln ('Ballot entered...');
  616.          seek (ufile,n);
  617.          write (ufile,u);
  618.          cv:=true;
  619.          end;
  620.          cnt:=cnt+1;
  621.          writeurec;
  622.          readurec;
  623.          end;
  624.         end;
  625.     If info='N' then begin
  626.          cv:=false;
  627.          cnt:=0;
  628.          seek (ufile,n);
  629.          u.newvoteno:=u.newvoteno+1;
  630.          addnuv;
  631.          while cnt<=50 do begin
  632.          if urec.newvoteit[cnt]=0 then begin
  633.          urec.newvoteit[cnt]:=n;
  634.          cnt:=50;
  635.          Writeln ('Ballot entered...');
  636.          If (u.newvoteno>=configset.vonumno) and (configset.autokillNUV) then Begin
  637.            WRiteLn('User has been Deleted!'); u.level:=-1; End;
  638.          seek (ufile,n);
  639.          write (ufile,u);
  640.          cv:=true;
  641.          end;
  642.          cnt:=cnt+1;
  643.          writeurec;
  644.          readurec;
  645.          end;
  646.          end;
  647.     If info='Q' then begin
  648.          cv:=false;
  649.          alv:=true;
  650.          if not alv then begin
  651.          writeln ('Thank You...');
  652.          end;
  653.          cv:=true;
  654.          end;
  655.     If info='G' then Begin
  656.          WriteLn('NUV was aborted...');
  657.          cv:=true;
  658.          exit;
  659.          end;
  660.     If info='V' then Begin
  661.         cv:=false;
  662.         showinfoforms(u.handle,5);
  663.         WriteStr(^P'Press ['^S'Enter'^P'] :*');
  664.         end;
  665.     If info='R' then showuser;
  666.     If info='L' then Begin
  667.       WriteHdr('Last Ten Users Voted On');
  668.       WriteLn;
  669.         If urec.nuv1>'' then WriteLn('1.' + urec.nuv1);
  670.         if urec.nuv2>'' then WriteLn('2.' + urec.nuv2);
  671.         if urec.nuv3>'' then writeln('3.' + urec.nuv3);
  672.         if urec.nuv4>'' then writeln('4.' + urec.nuv4);
  673.         if urec.nuv5>'' then writeln('5.' + urec.nuv5);
  674.         If urec.nuv6>'' then WriteLn('6.' + urec.nuv6);
  675.         if urec.nuv7>'' then WriteLn('7.' + urec.nuv7);
  676.         if urec.nuv8>'' then writeln('8.' + urec.nuv8);
  677.         if urec.nuv9>'' then writeln('9.' + urec.nuv9);
  678.         if urec.nuv10>'' then writeln('10.' + urec.nuv10);
  679.         WriteLn;
  680.       End;
  681.     If info='?' then Begin
  682.         WriteLn;
  683.         WriteLn(^R'['^S'Y'^R']'^P' - Give '^S+u.handle+^P' a '^U'YES'^P' vote');
  684.         WriteLn(^R'['^S'N'^R']'^P' - Give '^S+u.handle+^P' a '^U'NO'^P' vote');
  685.         WriteLn(^R'['^S'V'^R']'^P' - View '^S+u.handle+'''s'^P' New User Infoform');
  686.         WriteLn(^R'['^S'R'^R']'^P' - Review User''s Statistics');
  687.         WriteLn(^R'['^S'L'^R']'^P' - View Last 10 Users You have voted on');
  688.         WriteLn(^R'['^S'G'^R']'^P' - Go To Next User');
  689.         WriteLn(^R'['^S'Q'^R']'^P' - Abort NUV Procedures');
  690.         WriteLn;
  691.         End;
  692.    until cv;
  693.   end;
  694. end;
  695.  
  696. begin
  697. if urec.level<configset.newvotelvl then exit;
  698. If configset.UseNUV then Begin
  699.   alv:=true;
  700.   for n:=1 to numusers do begin
  701.   seek (ufile,n);
  702.   read (ufile,u);
  703.   name:=u.handle;
  704.   quit:=false;
  705.   if u.level=1 then Begin
  706.    If urec.nuv1=name then quit:=true;
  707.    If urec.nuv2=name then quit:=true;
  708.    if urec.nuv3=name then quit:=true;
  709.    If urec.nuv4=name then quit:=true;
  710.    if urec.nuv5=name then quit:=true;
  711.    If not quit then
  712.    showuser;
  713.    end;
  714.   end;
  715. end;
  716. end;
  717.  
  718. procedure checkvot;
  719.   var n:integer;
  720.       u:userrec;
  721.       nnu:integer;
  722.       name:mstr;
  723.       quit:Boolean;
  724. begin
  725.   If urec.level<configset.newvotelvl then exit;
  726.   If configset.UseNUV then Begin
  727.   nnu:=0;
  728.   for n:=1 to numusers do begin
  729.   seek (ufile,n);
  730.   read (ufile,u);
  731.   name:=u.handle;
  732.   quit:=false;
  733.   if u.level=1 then Begin
  734.    If urec.nuv1=name then quit:=true;
  735.    If urec.nuv2=name then quit:=true;
  736.    if urec.nuv3=name then quit:=true;
  737.    If urec.nuv4=name then quit:=true;
  738.    if urec.nuv5=name then quit:=true;
  739.    If not quit
  740.    then nnu:=nnu+1;
  741.    end;
  742.   end;
  743.   If nnu>0 then WriteStr(^R'There is '^S+strr(nnu)+^R' new user(s), vote on them? ['^P'N'^R']:*');
  744.   if yes then newvotex;
  745. end;
  746. end;
  747.  
  748. Procedure BoXFile;
  749. Begin
  750. If ansigraphics in urec.config then Begin
  751.       ClearScr;
  752.       printxy(1,1,'  '^O' ╒═'^F'['^U' File Upload '^F']'^O'══════════════════════════════╕');
  753.       printxy(2,1,'  '^O' │ '^A'Free Disk Space    :'^O'                         │');
  754.       printxy(3,1,'  '^O' ├──────────────────────────────────────────────┤');
  755.       printxy(4,1,'  '^O' │ '^S'File Name          :'^O'                         │');
  756.       printxy(5,1,'  '^O' │ '^S'Password <'^R'CR'^A'/'^R'None'^S'> :'^O'                         │');
  757.       printxy(6,1,'  '^O' │ '^S'Disk# :       '^O'                               │');
  758.       printxy(7,1,'  '^O' │ '^S'Description '^O'                                 │');
  759.       printxy(8,1,'  '^O' │ '^S':                                            '^O'│');
  760.       printxy(9,1,'  '^O' │ '^S'Private For <'^R'CR'^A'/'^R'None'^S'> :'^O'                      │');
  761.       printxy(10,1,' '^O'  ╘══════════════════════════════════════════════╛');
  762.       End;
  763. End;
  764.  
  765. Procedure ListingHelp;
  766. Begin
  767.   WriteLn(^R'[ '^A'File Listing Help '^R']'^M);
  768.   WriteLn(^R'['^F'+'^R'] '^P'- Add to Batch');
  769.   WriteLn(^R'['^F'D'^R'] '^P'- Download a File');
  770.   WriteLn(^R'['^F'V'^R'] '^P'- View Archive');
  771.   WriteLn(^R'['^F'Q'^R'] '^P'- Quit');
  772. End;
  773.  
  774. Procedure NewScanHelp;
  775. Begin
  776.   WriteLn(^R'[ '^A'File Newscan Help '^R']'^M);
  777.   WriteLn(^R'['^F'+'^R'] '^P'- Add to Batch');
  778.   WriteLn(^R'['^F'D'^R'] '^P'- Download a File');
  779.   WriteLn(^R'['^F'V'^R'] '^P'- View Archive');
  780.   WriteLn(^R'['^F'N'^R'] '^P'- Non-Stop');
  781.   WriteLn(^R'['^F'Q'^R'] '^P'- Quit');
  782. End;
  783.  
  784. Begin
  785. end.
  786.